/**
 * 通用msg service模块，提供msg提醒常用功能支持
 * 
 * @Date: 2015-6-16
 * @author: Jackson wang
 * @version: 1.0
 * @since: 1.0
 */
define(["jquery","jqueryNoty"],function ($,noty) {

			'use strict';
			var type={
				info:'information',
				warn:'warning',
				error:'error',
				success:'success'}
				
			var private_method={
				
				generate:function (type, text) {
					
					
					
		            var n = noty({
		                text        : text,
		                type        : type,
		                dismissQueue: true,
		                layout      : 'bottomRight',
		                closeWith   : ['click'],
		                theme       : 'relax',
		                maxVisible  : 10,
		                timeout		: 1000,
		                animation   : {
		                    open  : 'animated bounceInRight',
		                    close : 'animated bounceOutRight',
		                    easing: 'swing',
		                    speed : 500
		                }
		            });
		            if(window.console)
		            	console.log('html: ' + n.options.id);
		        }			
			}
			return {
				Msgslide : function(msg) {
					private_method.generate(type.info,msg)					
				},
				errSlide:function(msg){
					private_method.generate(type.error,msg)
				},
				warnSlide:function(msg){
					private_method.generate(type.warn,msg)
				},
				successSlide:function(msg){
					private_method.generate(type.success,msg)
				}
			};

		});